(* Content-type: application/mathematica *)

(*** Wolfram Notebook File ***)
(* http://www.wolfram.com/nb *)

(* CreatedBy='Mathematica 7.0' *)

(*CacheID: 234*)
(* Internal cache information:
NotebookFileLineBreakTest
NotebookFileLineBreakTest
NotebookDataPosition[       145,          7]
NotebookDataLength[     15833,        410]
NotebookOptionsPosition[     14841,        373]
NotebookOutlinePosition[     15186,        388]
CellTagsIndexPosition[     15143,        385]
WindowFrame->Normal*)

(* Beginning of Notebook Content *)
Notebook[{

Cell[CellGroupData[{
Cell["\<\
Enter the eigenvalue triple \[CapitalLambda] and the eigenframe u.  Usually u \
= id (Identity matrix) will be enough.\
\>", "Subsection",
 CellChangeTimes->{{3.5756843593450885`*^9, 3.575684375652117*^9}, {
  3.5947433995211554`*^9, 3.594743463871244*^9}, {3.5947440902891264`*^9, 
  3.594744094651633*^9}}],

Cell[BoxData[{
 RowBox[{
  RowBox[{"\[CapitalLambda]", "=", 
   RowBox[{"{", 
    RowBox[{"1", ",", "19", ",", 
     RowBox[{"-", "20"}]}], "}"}]}], ";", 
  RowBox[{"u", "=", "id"}], ";", 
  RowBox[{"eye", "=", 
   RowBox[{"5", 
    RowBox[{"xyztp", "[", 
     RowBox[{"{", 
      RowBox[{"35", ",", "70"}], "}"}], "]"}]}]}], ";", 
  RowBox[{"c", "=", 
   RowBox[{"{", 
    RowBox[{"0", ",", "0", ",", "0"}], "}"}]}], ";", 
  RowBox[{"BBrad", "=", "1"}], ";", " ", 
  RowBox[{"tkns", "=", ".006"}], ";"}], "\[IndentingNewLine]", 
 RowBox[{"Graphics3D", "[", 
  RowBox[{
   RowBox[{"BeachBall", "[", 
    RowBox[{"\[CapitalLambda]", ",", "u", ",", "c", ",", "BBrad"}], "]"}], 
   ",", 
   RowBox[{"ViewPoint", "\[Rule]", "eye"}], ",", 
   RowBox[{"Lighting", "\[Rule]", "\"\<Neutral\>\""}]}], "]"}]}], "Input",
 CellChangeTimes->{{3.54674739262261*^9, 3.5467474555843196`*^9}, {
   3.546747489670379*^9, 3.5467474928059845`*^9}, {3.546747595204563*^9, 
   3.546747680115511*^9}, {3.5467477303943987`*^9, 3.5467477874436984`*^9}, {
   3.546749587452837*^9, 3.546749611523679*^9}, {3.546750355956977*^9, 
   3.546750360605785*^9}, {3.546751230847118*^9, 3.546751233218322*^9}, {
   3.5467520384430313`*^9, 3.5467520533435574`*^9}, {3.5468748239565516`*^9, 
   3.5468748266241565`*^9}, {3.546875127595481*^9, 3.546875160776739*^9}, {
   3.5468751958768005`*^9, 3.5468751963760014`*^9}, {3.5468819079343176`*^9, 
   3.546881911257123*^9}, {3.546881941271576*^9, 3.546881977869239*^9}, {
   3.5468828201523085`*^9, 3.5468828203707085`*^9}, {3.5468849456050315`*^9, 
   3.5468849741062813`*^9}, {3.546912390478277*^9, 3.5469124053607035`*^9}, 
   3.5469124934660573`*^9, 3.5469151993638725`*^9, 3.5469156234400225`*^9, 
   3.546964329241476*^9, 3.575683900754984*^9, {3.5756840574186583`*^9, 
   3.575684071396283*^9}, {3.5920787426770315`*^9, 3.5920787704170694`*^9}, {
   3.594259503154374*^9, 3.594259511424385*^9}, {3.5942596392645617`*^9, 
   3.59425964491457*^9}, {3.594261177246703*^9, 3.594261180126707*^9}, {
   3.594262020591875*^9, 3.5942620429119062`*^9}, 3.5942622089561377`*^9, {
   3.5944819860373063`*^9, 3.594481994399319*^9}, {3.594482150757042*^9, 
   3.594482152497044*^9}, {3.5947433853211355`*^9, 3.594743390361142*^9}, {
   3.594743479061265*^9, 3.5947434880212774`*^9}, {3.5947437777681804`*^9, 
   3.5947438069182205`*^9}}],

Cell[BoxData[{
 RowBox[{
  RowBox[{"\[CapitalLambda]", "=", 
   RowBox[{"{", 
    RowBox[{"1", ",", "19", ",", 
     RowBox[{"-", "20"}]}], "}"}]}], ";", 
  RowBox[{"u", "=", 
   RowBox[{"xrot", "[", "30", "]"}]}], ";", 
  RowBox[{"eye", "=", 
   RowBox[{"5", 
    RowBox[{"xyztp", "[", 
     RowBox[{"{", 
      RowBox[{"35", ",", "70"}], "}"}], "]"}]}]}], ";", 
  RowBox[{"c", "=", 
   RowBox[{"{", 
    RowBox[{"0", ",", "0", ",", "0"}], "}"}]}], ";", 
  RowBox[{"BBrad", "=", "1"}], ";", " ", 
  RowBox[{"tkns", "=", ".006"}], ";"}], "\[IndentingNewLine]", 
 RowBox[{"Graphics3D", "[", 
  RowBox[{
   RowBox[{"BeachBall", "[", 
    RowBox[{"\[CapitalLambda]", ",", "u", ",", "c", ",", "BBrad"}], "]"}], 
   ",", 
   RowBox[{"ViewPoint", "\[Rule]", "eye"}], ",", 
   RowBox[{"Lighting", "\[Rule]", "\"\<Neutral\>\""}], ",", 
   RowBox[{"Boxed", "\[Rule]", "False"}]}], "]"}]}], "Input",
 CellChangeTimes->{{3.5947435264063306`*^9, 3.594743563386382*^9}}],

Cell[BoxData[{
 RowBox[{
  RowBox[{"\[CapitalLambda]", "=", 
   RowBox[{"{", 
    RowBox[{"1", ",", "19", ",", 
     RowBox[{"-", "20"}]}], "}"}]}], ";", 
  RowBox[{"u", "=", 
   RowBox[{"xrot", "[", "30", "]"}]}], ";", 
  RowBox[{"eye", "=", 
   RowBox[{"5", 
    RowBox[{"xyztp", "[", 
     RowBox[{"{", 
      RowBox[{"35", ",", "70"}], "}"}], "]"}]}]}], ";", 
  RowBox[{"c", "=", 
   RowBox[{"{", 
    RowBox[{"0", ",", "0", ",", "0"}], "}"}]}], ";", 
  RowBox[{"BBrad", "=", "1"}], ";", " ", 
  RowBox[{"tkns", "=", ".006"}], ";", 
  RowBox[{"ArrowScale", "=", ".07"}], ";"}], "\[IndentingNewLine]", 
 RowBox[{"Graphics3D", "[", 
  RowBox[{
   RowBox[{"{", 
    RowBox[{
     RowBox[{"BeachBall", "[", 
      RowBox[{"\[CapitalLambda]", ",", "u", ",", "c", ",", "BBrad"}], "]"}], 
     ",", "\[IndentingNewLine]", 
     RowBox[{"Paxes", "[", 
      RowBox[{"True", ",", "True", ",", "True", ",", "u", ",", "c", ",", 
       RowBox[{"1.5", "BBrad"}], ",", "BBrad", ",", "ArrowScale", ",", 
       RowBox[{"1.5", "tkns"}], ",", "eye", ",", "True"}], "]"}]}], "}"}], 
   ",", 
   RowBox[{"ViewPoint", "\[Rule]", "eye"}], ",", 
   RowBox[{"Lighting", "\[Rule]", "\"\<Neutral\>\""}], ",", 
   RowBox[{"Boxed", "\[Rule]", "False"}]}], "]"}]}], "Input",
 CellChangeTimes->{
  3.5947435734163957`*^9, {3.594743678604041*^9, 3.594743746374135*^9}}],

Cell[BoxData[{
 RowBox[{
  RowBox[{"\[CapitalLambda]", "=", 
   RowBox[{"{", 
    RowBox[{"1", ",", "0", ",", 
     RowBox[{"-", "1"}]}], "}"}]}], ";", 
  RowBox[{"u", "=", 
   RowBox[{"xrot", "[", "30", "]"}]}], ";", 
  RowBox[{"eye", "=", 
   RowBox[{"5", 
    RowBox[{"xyztp", "[", 
     RowBox[{"{", 
      RowBox[{"35", ",", "70"}], "}"}], "]"}]}]}], ";", 
  RowBox[{"c", "=", 
   RowBox[{"{", 
    RowBox[{"0", ",", "0", ",", "0"}], "}"}]}], ";", 
  RowBox[{"BBrad", "=", "1"}], ";", " ", 
  RowBox[{"tkns", "=", ".006"}], ";", 
  RowBox[{"ArrowScale", "=", ".07"}], ";"}], "\[IndentingNewLine]", 
 RowBox[{"Graphics3D", "[", 
  RowBox[{
   RowBox[{"{", 
    RowBox[{
     RowBox[{"BeachBall", "[", 
      RowBox[{"\[CapitalLambda]", ",", "u", ",", "c", ",", "BBrad"}], "]"}], 
     ",", "\[IndentingNewLine]", 
     RowBox[{"Paxes", "[", 
      RowBox[{"True", ",", "True", ",", "True", ",", "u", ",", "c", ",", 
       RowBox[{"1.5", "BBrad"}], ",", "BBrad", ",", "ArrowScale", ",", 
       RowBox[{"1.5", "tkns"}], ",", "eye", ",", "True"}], "]"}]}], "}"}], 
   ",", 
   RowBox[{"ViewPoint", "\[Rule]", "eye"}], ",", 
   RowBox[{"Lighting", "\[Rule]", "\"\<Neutral\>\""}], ",", 
   RowBox[{"Boxed", "\[Rule]", "False"}]}], "]"}]}], "Input",
 CellChangeTimes->{
  3.5947435734163957`*^9, {3.594743678604041*^9, 3.594743746374135*^9}, {
   3.594743972461953*^9, 3.5947439744719563`*^9}}],

Cell[BoxData[{
 RowBox[{
  RowBox[{"\[CapitalLambda]", "=", 
   RowBox[{"{", 
    RowBox[{"3", ",", "1", ",", "1"}], "}"}]}], ";", 
  RowBox[{"u", "=", 
   RowBox[{"yrot", "[", "30", "]"}]}], ";", 
  RowBox[{"eye", "=", 
   RowBox[{"5", 
    RowBox[{"xyztp", "[", 
     RowBox[{"{", 
      RowBox[{"35", ",", "70"}], "}"}], "]"}]}]}], ";", 
  RowBox[{"c", "=", 
   RowBox[{"{", 
    RowBox[{"0", ",", "0", ",", "0"}], "}"}]}], ";", 
  RowBox[{"BBrad", "=", "1"}], ";", " ", 
  RowBox[{"tkns", "=", ".006"}], ";"}], "\[IndentingNewLine]", 
 RowBox[{"Graphics3D", "[", 
  RowBox[{
   RowBox[{"BeachBall", "[", 
    RowBox[{"\[CapitalLambda]", ",", "u", ",", "c", ",", "BBrad"}], "]"}], 
   ",", 
   RowBox[{"ViewPoint", "\[Rule]", "eye"}], ",", 
   RowBox[{"Lighting", "\[Rule]", "\"\<Neutral\>\""}]}], "]"}]}], "Input",
 CellChangeTimes->{{3.54674739262261*^9, 3.5467474555843196`*^9}, {
   3.546747489670379*^9, 3.5467474928059845`*^9}, {3.546747595204563*^9, 
   3.546747680115511*^9}, {3.5467477303943987`*^9, 3.5467477874436984`*^9}, {
   3.546749587452837*^9, 3.546749611523679*^9}, {3.546750355956977*^9, 
   3.546750360605785*^9}, {3.546751230847118*^9, 3.546751233218322*^9}, {
   3.5467520384430313`*^9, 3.5467520533435574`*^9}, {3.5468748239565516`*^9, 
   3.5468748266241565`*^9}, {3.546875127595481*^9, 3.546875160776739*^9}, {
   3.5468751958768005`*^9, 3.5468751963760014`*^9}, {3.5468819079343176`*^9, 
   3.546881911257123*^9}, {3.546881941271576*^9, 3.546881977869239*^9}, {
   3.5468828201523085`*^9, 3.5468828203707085`*^9}, {3.5468849456050315`*^9, 
   3.5468849741062813`*^9}, {3.546912390478277*^9, 3.5469124053607035`*^9}, 
   3.5469124934660573`*^9, 3.5469151993638725`*^9, 3.5469156234400225`*^9, 
   3.546964329241476*^9, {3.557848520391572*^9, 3.5578485217643747`*^9}, {
   3.5578486380001774`*^9, 3.5578486681082296`*^9}, 3.557934173358012*^9, {
   3.5579484727585306`*^9, 3.5579484768457375`*^9}, 3.5947439289348917`*^9, 
   3.594746742942459*^9}],

Cell[TextData[StyleBox["The beachballs can be rotated with the mouse.",
 FontFamily->"Times New Roman",
 FontSize->14]], "Text",
 CellChangeTimes->{{3.5517191256512923`*^9, 3.551719137460513*^9}, 
   3.5947439982119884`*^9},
 FontColor->RGBColor[1, 0, 0]]
}, Open  ]],

Cell[CellGroupData[{

Cell["\<\
If your basis is south - east - up then this choice of eye (in red font) will \
show you the top view, with north towards the top of the page and east to the \
right.\
\>", "Subsection",
 CellChangeTimes->{{3.5756844140593834`*^9, 3.5756845283508835`*^9}, {
  3.575684688920865*^9, 3.575684689466866*^9}, {3.5756849452107134`*^9, 
  3.5756849493603206`*^9}, {3.594747020471349*^9, 3.5947470251313553`*^9}}],

Cell[BoxData[{
 RowBox[{
  RowBox[{"\[CapitalLambda]", "=", 
   RowBox[{"{", 
    RowBox[{"1", ",", "19", ",", 
     RowBox[{"-", "20"}]}], "}"}]}], ";", 
  RowBox[{"u", "=", 
   RowBox[{
    RowBox[{"xrot", "[", "20", "]"}], ".", 
    RowBox[{"yrot", "[", "10", "]"}]}]}], ";", 
  StyleBox[
   RowBox[{"eye", "=", 
    RowBox[{"{", 
     RowBox[{".1", ",", "0", ",", "100"}], "}"}]}],
   FontColor->RGBColor[1, 0, 0]], 
  StyleBox[";",
   FontColor->RGBColor[1, 0, 0]], 
  RowBox[{"c", "=", 
   RowBox[{"{", 
    RowBox[{"0", ",", "0", ",", "0"}], "}"}]}], ";", 
  RowBox[{"BBrad", "=", "1"}], ";", " ", 
  RowBox[{"tkns", "=", ".006"}], ";"}], "\[IndentingNewLine]", 
 RowBox[{"Graphics3D", "[", 
  RowBox[{
   RowBox[{"BeachBall", "[", 
    RowBox[{"\[CapitalLambda]", ",", "u", ",", "c", ",", "BBrad"}], "]"}], 
   ",", 
   RowBox[{"ViewPoint", "\[Rule]", "eye"}], ",", 
   RowBox[{"Lighting", "\[Rule]", "\"\<Neutral\>\""}]}], "]"}]}], "Input",
 CellChangeTimes->{
  3.57568468038515*^9, {3.5947466747683625`*^9, 3.59474667923037*^9}, 
   3.594746710782415*^9, {3.5947467610244856`*^9, 3.5947467718145003`*^9}, {
   3.5947468271870766`*^9, 3.59474683676709*^9}}]
}, Open  ]],

Cell[CellGroupData[{

Cell["The lighting choice flattens everything out.", "Subsection",
 CellChangeTimes->{{3.5756844140593834`*^9, 3.5756845283508835`*^9}, {
  3.575684707314497*^9, 3.575684709514101*^9}, {3.594746867101633*^9, 
  3.5947468679116344`*^9}}],

Cell[BoxData[
 RowBox[{"Graphics3D", "[", 
  RowBox[{
   RowBox[{"BeachBall", "[", 
    RowBox[{"\[CapitalLambda]", ",", "u", ",", "c", ",", "BBrad"}], "]"}], 
   ",", 
   RowBox[{"ViewPoint", "\[Rule]", "eye"}], ",", 
   StyleBox[
    RowBox[{"Lighting", "\[Rule]", 
     RowBox[{"{", 
      RowBox[{"{", 
       RowBox[{"\"\<Ambient\>\"", ",", "White"}], "}"}], "}"}]}],
    FontColor->RGBColor[1, 0, 0]]}], "]"}]], "Input",
 CellChangeTimes->{{3.54674739262261*^9, 3.5467474555843196`*^9}, {
   3.546747489670379*^9, 3.5467474928059845`*^9}, {3.546747595204563*^9, 
   3.546747680115511*^9}, {3.5467477303943987`*^9, 3.5467477874436984`*^9}, {
   3.546749587452837*^9, 3.546749611523679*^9}, {3.546750355956977*^9, 
   3.546750360605785*^9}, {3.546751230847118*^9, 3.546751233218322*^9}, {
   3.5467520384430313`*^9, 3.5467520533435574`*^9}, {3.5468748239565516`*^9, 
   3.5468748266241565`*^9}, {3.546875127595481*^9, 3.546875160776739*^9}, {
   3.5468751958768005`*^9, 3.5468751963760014`*^9}, {3.5468819079343176`*^9, 
   3.546881911257123*^9}, {3.546881941271576*^9, 3.546881977869239*^9}, {
   3.5468828201523085`*^9, 3.5468828203707085`*^9}, {3.5468849456050315`*^9, 
   3.5468849741062813`*^9}, {3.546912390478277*^9, 3.5469124053607035`*^9}, 
   3.5469124934660573`*^9, 3.5469151993638725`*^9, 3.5469156234400225`*^9, 
   3.546964329241476*^9, {3.575683873515436*^9, 3.5756839058717933`*^9}, {
   3.575684003319564*^9, 3.5756840681982775`*^9}, {3.575684130144287*^9, 
   3.575684141703907*^9}, 3.5756842363686724`*^9, {3.575684304039791*^9, 
   3.575684307112996*^9}, {3.5756847150702105`*^9, 3.5756847161073127`*^9}}]
}, Open  ]],

Cell[CellGroupData[{

Cell["\<\
Rotating 180deg about the vertical is the same as looking at the lower \
hemisphere.\
\>", "Subsection",
 CellChangeTimes->{{3.5756844140593834`*^9, 3.5756845283508835`*^9}, {
  3.575684707314497*^9, 3.575684709514101*^9}, {3.57568477745352*^9, 
  3.575684802400463*^9}}],

Cell[BoxData[{
 RowBox[{
  RowBox[{"u", "=", 
   RowBox[{
    StyleBox[
     RowBox[{"zrot", "[", "180", "]"}],
     FontColor->RGBColor[1, 0, 0]], ".", 
    RowBox[{"xrot", "[", "20", "]"}], ".", 
    RowBox[{"yrot", "[", "10", "]"}]}]}], ";"}], "\[IndentingNewLine]", 
 RowBox[{"Graphics3D", "[", 
  RowBox[{
   RowBox[{"BeachBall", "[", 
    RowBox[{"\[CapitalLambda]", ",", "u", ",", "c", ",", "BBrad"}], "]"}], 
   ",", 
   RowBox[{"ViewPoint", "\[Rule]", "eye"}], ",", 
   RowBox[{"Lighting", "\[Rule]", 
    RowBox[{"{", 
     RowBox[{"{", 
      RowBox[{"\"\<Ambient\>\"", ",", "White"}], "}"}], "}"}]}]}], 
  "]"}]}], "Input",
 CellChangeTimes->{{3.57568410347134*^9, 3.5756841110529537`*^9}, 
   3.5756842437630854`*^9, {3.575684542216208*^9, 3.5756845677141523`*^9}, {
   3.5756847468624663`*^9, 3.5756847573144846`*^9}, {3.5947487116827807`*^9, 
   3.5947487199552927`*^9}}]
}, Open  ]],

Cell[CellGroupData[{

Cell["Get rid of the box if you want.", "Subsection",
 CellChangeTimes->{{3.5756844140593834`*^9, 3.5756845283508835`*^9}, {
  3.575684707314497*^9, 3.575684709514101*^9}, {3.57568477745352*^9, 
  3.575684802400463*^9}, {3.575685071363234*^9, 3.575685077332445*^9}}],

Cell[BoxData[
 RowBox[{"Graphics3D", "[", 
  RowBox[{
   RowBox[{"BeachBall", "[", 
    RowBox[{"\[CapitalLambda]", ",", "u", ",", "c", ",", "BBrad"}], "]"}], 
   ",", 
   RowBox[{"ViewPoint", "\[Rule]", "eye"}], ",", 
   RowBox[{"Lighting", "\[Rule]", 
    RowBox[{"{", 
     RowBox[{"{", 
      RowBox[{"\"\<Ambient\>\"", ",", "White"}], "}"}], "}"}]}], ",", 
   StyleBox[
    RowBox[{"Boxed", "\[Rule]", "False"}],
    FontColor->RGBColor[1, 0, 0]]}], "]"}]], "Input",
 CellChangeTimes->{{3.5756850071260214`*^9, 3.5756850116500297`*^9}, 
   3.5756850477709928`*^9, {3.575685081390952*^9, 3.575685082467354*^9}}]
}, Open  ]]
},
WindowSize->{1281, 750},
WindowMargins->{{71, Automatic}, {90, Automatic}},
FrontEndVersion->"7.0 for Microsoft Windows (32-bit) (January 30, 2009)",
StyleDefinitions->"Default.nb"
]
(* End of Notebook Content *)

(* Internal cache information *)
(*CellTagsOutline
CellTagsIndex->{}
*)
(*CellTagsIndex
CellTagsIndex->{}
*)
(*NotebookFileOutline
Notebook[{
Cell[CellGroupData[{
Cell[567, 22, 318, 6, 36, "Subsection"],
Cell[888, 30, 2341, 44, 52, "Input"],
Cell[3232, 76, 957, 26, 52, "Input"],
Cell[4192, 104, 1344, 35, 72, "Input"],
Cell[5539, 141, 1394, 36, 72, "Input"],
Cell[6936, 179, 1975, 39, 52, "Input"],
Cell[8914, 220, 255, 5, 30, "Text"]
}, Open  ]],
Cell[CellGroupData[{
Cell[9206, 230, 416, 7, 36, "Subsection"],
Cell[9625, 239, 1167, 32, 52, "Input"]
}, Open  ]],
Cell[CellGroupData[{
Cell[10829, 276, 236, 3, 36, "Subsection"],
Cell[11068, 281, 1629, 28, 31, "Input"]
}, Open  ]],
Cell[CellGroupData[{
Cell[12734, 314, 281, 6, 36, "Subsection"],
Cell[13018, 322, 886, 23, 52, "Input"]
}, Open  ]],
Cell[CellGroupData[{
Cell[13941, 350, 266, 3, 36, "Subsection"],
Cell[14210, 355, 615, 15, 31, "Input"]
}, Open  ]]
}
]
*)

(* End of internal cache information *)
